<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Insert title here</title>
</head>
<body>
	
	<script type="text/javascript">
		var student = {
			id : 12,
			name : '张三',
			age : 23,
			study : function() {
				console.log('name: ' + this.name + ', age: ' + this.age);
			}
		}
		console.log(student.name);
		student.study();
		
		var list = [
			{
				'id' : 23,
				'name' : 'zhangsan',
				'age' : 23,
				'gender' : '男'
			},
			{
				'id' : 23,
				'name' : 'zhangsan',
				'age' : 23,
				'gender' : '男',
				'interests' : [
					{'name' : '篮球', 'time' : 4},
					{'name' : '足球', 'time' : 5},
					{'name' : '羽毛球', 'time' : 3},
				]
			}
			
		];
		
		console.log(list[1].gender);
		console.log(list[1].interests[2]);// {'name' : '羽毛球', 'time' : 3}
		console.log(list[1].interests[2].time);// 3
	</script>
</body>
</html>